import React, { Component } from 'react';
import PropTypes from 'prop-types'
class Child extends Component {
    render() {
        return (
            <div>
                <h1>子组件---{this.props.username}</h1>
            </div>
        );
    }
}
Child.propTypes = {
    username:PropTypes.string
}

export default Child;